package practice;

import java.util.*;

public class Text01 {
    public static void main(String[] args) {
        Collection<Integer> a=new ArrayList<>();
        Scanner scan=new Scanner(System.in);
        int num=0;
        while (true){
            if(num<200){
                System.out.println("请输入");
                a.add(scan.nextInt());
                Iterator<Integer> it=a.iterator();
                num=0;
                while (it.hasNext()){
                    Integer s=it.next();
                    num=num+s;
                }
            }else {
                System.out.println(num);
                break;
            }
        }
    }
}
